/******************************************************************************
* @file spiFlash.h
* @author Zohar
* @version 1.00
* @date 2019.09.21
* @brief
******************************************************************************/
#ifndef __SPI_FLASH_H__
#define __SPI_FLASH_H__
#include "spi.h"

void SPI_FLASH_SectorErase(uint32_t Addr);
void SPI_FLASH_ChipErase(void);
void SPI_FLASH_PageWrite(uint8_t *pBuffer, uint32_t Addr, uint16_t Num);
void SPI_FLASH_BufferWrite(uint8_t *pBuffer, uint32_t Addr, uint16_t Num);
void SPI_FLASH_BufferRead(uint8_t *pBuffer, uint32_t Addr, uint32_t Num);

void TestFlash(void);
void GetDataInSpiFlash(uint32_t sectorAdd, uint32_t sectorNum);

#endif //__SPI_FLASH_H__
